<?php
    
    class Music extends Index{
    	
		public function __construct(){
			parent::__construct();
		}
		
		public function setPlugIn(){
			return array("page.php");
		}
		
		public function Index(){
			
		}
		
		public function AjaxMusicList(){
			$sql = "";
			if($_GET['title']){
				$title = $_GET['title'];
				$sql = "where `title` like '%{$title}%'";
			}
			$page = new Page(8,"select * from `ntwt_music` ".$sql);
			$this->_T['PageList']['con']      = $page->content;
			$this->_T['PageList']['rowNum'] = $page->num;
			$this->_T['PageList']['pageOne']  = $page->first_page;
			$this->_T['PageList']['pageLast'] = $page->last_page;
			$this->_T['PageList']['pageVal']  = $page->pageval;
			$this->_T['PageList']['pagePre']  = $page->pageval-1;
			$this->_T['PageList']['pageNext'] = $page->pageval+1;
			$this->_T['PageList']['PageNum']  = count($page->content);
			echo json_encode($this->_T);
		}
		
		
    }











?>